<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      let json = '{"a":"666","b":"gogogo"}';
      console.log(JSON.parse(json)); // JSON字符串 转换为JS对象
      let obj = {
        a: "你好",
        b: "yoyoyo",
      };
      console.log(JSON.stringify(obj)); // 将JS对象 转换为JSON字符串
    </script>
  </body>
</html>
